<?php
abstract class DataProvider{

	abstract function get_events($datestart,$datefinish,$type)	;	
	abstract function get_repeated_events($datestart,$type);

	abstract function get_event($event_id);
	abstract function update_event($data,$event_id);
	abstract function delete_event($event_id);
	abstract function insert_event($data);

	abstract function get_event_repeat($event_id);
	abstract function set_event_repeat($data,$event_id);
	abstract function delete_event_repeat($event_id);
	
	abstract function get_calendars($user_id=null);
	abstract function insert_calendar($data);
	abstract function update_calendar($data,$calendar_id);
	abstract function delete_calendar($calendar_id);
	
	abstract function bind_calendar_to_user($calendar_id,$user_id);

	
		
}

include "data_providers/mssql.php";
$db_conf=array(
			'host'     => 'MARCO-PC',
			'username' => 'jqalendar',
			'password' => 'jqalendar',
			'dbname'   => 'jqalendar'
		);
$data_provider=new MSSQLDataProvider($db_conf);
